home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / programm.ing / wx_lib10.zoo / wx_tst.c < prev   
Encoding:
C/C++ Source or Header  |  1992-08-02  |  1.4 KB  |  60 lines

  1. #include <wx_lib.h>
  2. #include <alloc.h>
  3.  
  4. void    main()
  5. {
  6.     int        count,
  7.             vh,
  8.             gh,
  9.             junk,
  10.             gl_wchar,
  11.             gl_hchar,
  12.             work_in[11],
  13.             work_out[57];
  14.     Window    ws;
  15.  
  16.     /* Initialization */
  17.     appl_init();
  18.     gh = graf_handle(&gl_wchar,&gl_hchar,&junk,&junk);
  19.     for (count = 0;count < 10;count ++) {
  20.         work_in[count] = 1;
  21.     }
  22.     work_in[10] = 2;
  23.     vh = gh;
  24.     v_opnvwk(work_in,&vh,work_out);
  25.     /* Workout */
  26.     wx_init(&ws,vh,gl_wchar,gl_hchar);
  27.     wx_new(&ws);
  28.     wx_settype(&ws,INFO|NAME|MOVER|FULLER|CLOSER);
  29.     wx_open(&ws);
  30.     wx_name(&ws,"This is a test.");
  31.     wx_info(&ws,"Wombats have been here.");
  32.     wx_clear(&ws);
  33.     wx_puts(&ws,"This is a test of wx_puts().\n");
  34.     wx_printf(&ws,"This is another test, this time of wx_printf().\n");
  35.     for (count = 1;count <= 30;count++) {
  36.         wx_printf(&ws,"This is a bigger test of wx_printf().\n#%d.\n",count);
  37.     }
  38.     for (count = 1;count <= 50;count ++) {
  39.         wx_printf(&ws,"This");
  40.     }
  41.     wx_size(&ws,100,100);
  42.     wx_clear(&ws);
  43.     for (count = 1;count <= 30;count++) {
  44.         wx_printf(&ws,"This is a bigger test of wx_printf().\n#%d.\n",count);
  45.     }
  46.     wx_move(&ws,30,30);
  47.     wx_clear(&ws);
  48.     for (count = 1;count <= 30;count++) {
  49.         wx_printf(&ws,"This is a bigger test of wx_printf().\n#%d.\n",count);
  50.     }
  51.     wx_full(&ws);
  52.     wx_clear(&ws);
  53.     for (count = 1;count <= 30;count++) {
  54.         wx_printf(&ws,"This is a bigger test of wx_printf().\n#%d.\n",count);
  55.     }
  56.     wx_close(&ws);
  57.     wx_free(&ws);
  58.     appl_exit();
  59. }
  60.